#ifndef SPLITTER_H
#define SPLITTER_H

#include "qdock.h"
#include "containers.h"

class USplitter : public IndexedContainer {
    Q_OBJECT
public:
    USplitter(Qt::Orientation orient = Qt::Horizontal, QWidget* parent = 0);
//    virtual ~USplitter();
    virtual int dockingIndex(DockOption dockoption, QWidget* relativeAnchor = 0);
    virtual void insertWidget(int index, QWidget* widget);
    virtual void removeWidget(QWidget* widget);
    virtual int indexOf(QWidget *widget);
    virtual QWidget* widgetAt(int index);
    virtual void replaceWidget(QWidget *old_widgets, QWidget *new_widget);
    Qt::Orientation orientation(){return m_splitter->orientation();}
    virtual int count(){return m_splitter->count();}
    virtual bool isHandlerFor(DockOption dockoption);
    virtual QRect simulateDrop(QDockItem *dragged_widget, QWidget *target_widget, DockOption dockoption);
protected:

//    void childEvent(QChildEvent * event);
protected://fields
    QSplitter* m_splitter;
};

#endif // SPLITTER_H
